<template>
    <van-swipe-cell>
        <van-cell
            :title="Rusername"
            :value="Rtel"
            size="large"
            :label="Raddress"
        />
    </van-swipe-cell>
    <van-swipe-cell v-for="item in checkGoodsList">
        <van-card
            class="g-card"
            :price="item.price"
            :desc="item.detail"
            :title="item.product"
            :origin-price="item.oldprice"
        >
            <template #thumb>
                <div class="g-thumb">
                    <van-image :src="item.picture" />
                </div>
            </template>
            <template #tags>
                <van-tag plain type="danger">{{ item.shop }}</van-tag>
            </template>
            <template #footer>
                <van-stepper
                    v-model="item.num"
                    theme="round"
                    button-size="22"
                    disable-input
                />
            </template>
        </van-card>
    </van-swipe-cell>
    <van-submit-bar
        :price="payOderStore.totalPrice"
        button-text="去支付"
        @submit="bindGoPay"
    />
</template>

<script lang="ts" setup>
import { usePayOder } from '@/hooks/payOder'
import { useOnAdd } from '@/hooks/onAdd'
import { useRoute } from 'vue-router'
const route = useRoute()
const { payOderStore, checkGoodsList, bindGoPay, oderList, } = usePayOder()
const { username, tel, address } = useOnAdd()
const Rusername = route.query.username
const Rtel = route.query.tel
const Raddress = route.query.address
</script>

<style lang="scss" scoped></style>
